﻿<!--
//===============================================================================
// Microsoft Architecture Strategy Team
// LitwareHR - S+S Sample Application
//===============================================================================
// Copyright  Microsoft Corporation.  All rights reserved.
// THIS CODE AND INFORMATION IS PROVIDED "AS IS" WITHOUT WARRANTY
// OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT
// LIMITED TO THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
// FITNESS FOR A PARTICULAR PURPOSE.
//===============================================================================
// The example companies, organizations, products, domain names,
// e-mail addresses, logos, people, places, and events depicted
// herein are fictitious.  No association with any real company,
// organization, product, domain name, email address, logo, person,
// places, or events is intended or should be inferred.
//===============================================================================
-->

<UserControl
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" x:Class="LitwareHR.PublicApp.WinUX.LinkView"
    >
	<UserControl.Resources>
		<!--<ResourceDictionary>
			<ResourceDictionary.MergedDictionaries>
				<ResourceDictionary Source="ButtonStyles.xaml"/>
			</ResourceDictionary.MergedDictionaries>
		</ResourceDictionary>-->
		<Style x:Key="NormalLinkButtonStyle" BasedOn="{x:Null}" TargetType="{x:Type Button}">
			<Setter Property="Template">
				<Setter.Value>
					<ControlTemplate TargetType="{x:Type Button}">
						<ControlTemplate.Resources>
							<Storyboard x:Key="Timeline1">
								<ColorAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="BottomGlow" Storyboard.TargetProperty="(Shape.Fill).(GradientBrush.GradientStops)[0].(GradientStop.Color)">
									<SplineColorKeyFrame KeyTime="00:00:00" Value="#00000000"/>
									<SplineColorKeyFrame KeyTime="00:00:00.1500000" Value="#FFC2FF00"/>
								</ColorAnimationUsingKeyFrames>
								<ColorAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="BottomGlow" Storyboard.TargetProperty="(Shape.Fill).(GradientBrush.GradientStops)[1].(GradientStop.Color)">
									<SplineColorKeyFrame KeyTime="00:00:00" Value="#00FFFFFF"/>
								</ColorAnimationUsingKeyFrames>
								<DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="BottomGlow" Storyboard.TargetProperty="(Shape.Fill).(Brush.RelativeTransform).(TransformGroup.Children)[3].(TranslateTransform.X)">
									<SplineDoubleKeyFrame KeyTime="00:00:00" Value="-0.019"/>
								</DoubleAnimationUsingKeyFrames>
								<DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="BottomGlow" Storyboard.TargetProperty="(Shape.Fill).(Brush.RelativeTransform).(TransformGroup.Children)[3].(TranslateTransform.Y)">
									<SplineDoubleKeyFrame KeyTime="00:00:00" Value="0.59"/>
									<SplineDoubleKeyFrame KeyTime="00:00:00.1500000" Value="0.535"/>
								</DoubleAnimationUsingKeyFrames>
								<DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="BottomGlow" Storyboard.TargetProperty="(Shape.Fill).(Brush.RelativeTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleX)">
									<SplineDoubleKeyFrame KeyTime="00:00:00" Value="1.938"/>
								</DoubleAnimationUsingKeyFrames>
								<DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="BottomGlow" Storyboard.TargetProperty="(Shape.Fill).(Brush.RelativeTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleY)">
									<SplineDoubleKeyFrame KeyTime="00:00:00" Value="0.708"/>
									<SplineDoubleKeyFrame KeyTime="00:00:00.1500000" Value="0.791"/>
								</DoubleAnimationUsingKeyFrames>
								<DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="BottomGlow" Storyboard.TargetProperty="(UIElement.Opacity)">
									<SplineDoubleKeyFrame KeyTime="00:00:00" Value="0.8"/>
									<SplineDoubleKeyFrame KeyTime="00:00:00.1500000" Value="1"/>
								</DoubleAnimationUsingKeyFrames>
							</Storyboard>
							<Storyboard x:Key="Timeline2">
								<ColorAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetProperty="(Shape.Fill).(GradientBrush.GradientStops)[0].(GradientStop.Color)" Storyboard.TargetName="BottomGlow">
									<SplineColorKeyFrame KeyTime="00:00:00" Value="#FFC2FF00"/>
									<SplineColorKeyFrame KeyTime="00:00:00.2600000" Value="#00C2FF00"/>
								</ColorAnimationUsingKeyFrames>
								<ColorAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetProperty="(Shape.Fill).(GradientBrush.GradientStops)[1].(GradientStop.Color)" Storyboard.TargetName="BottomGlow">
									<SplineColorKeyFrame KeyTime="00:00:00" Value="#00FFFFFF"/>
								</ColorAnimationUsingKeyFrames>
								<DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetProperty="(Shape.Fill).(Brush.RelativeTransform).(TransformGroup.Children)[3].(TranslateTransform.X)" Storyboard.TargetName="BottomGlow">
									<SplineDoubleKeyFrame KeyTime="00:00:00" Value="-0.045"/>
								</DoubleAnimationUsingKeyFrames>
								<DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetProperty="(Shape.Fill).(Brush.RelativeTransform).(TransformGroup.Children)[3].(TranslateTransform.Y)" Storyboard.TargetName="BottomGlow">
									<SplineDoubleKeyFrame KeyTime="00:00:00" Value="0.463"/>
								</DoubleAnimationUsingKeyFrames>
								<DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetProperty="(Shape.Fill).(Brush.RelativeTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleX)" Storyboard.TargetName="BottomGlow">
									<SplineDoubleKeyFrame KeyTime="00:00:00" Value="1.933"/>
								</DoubleAnimationUsingKeyFrames>
								<DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetProperty="(Shape.Fill).(Brush.RelativeTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleY)" Storyboard.TargetName="BottomGlow">
									<SplineDoubleKeyFrame KeyTime="00:00:00" Value="0.919"/>
								</DoubleAnimationUsingKeyFrames>
								<DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="BottomGlow" Storyboard.TargetProperty="(UIElement.Opacity)">
									<SplineDoubleKeyFrame KeyTime="00:00:00" Value="1"/>
									<SplineDoubleKeyFrame KeyTime="00:00:00.2580000" Value="0.8"/>
									<SplineDoubleKeyFrame KeyTime="00:00:00.2600000" Value="0.9"/>
								</DoubleAnimationUsingKeyFrames>
							</Storyboard>
						</ControlTemplate.Resources>
						<Grid>
							<Rectangle Stroke="{x:Null}" RadiusX="10" RadiusY="10" x:Name="Reflection" Margin="0,0,0,-20.646" VerticalAlignment="Bottom" Height="18">
								<Rectangle.Fill>
									<LinearGradientBrush EndPoint="0.497,0.515" StartPoint="0.499,-0.119">
										<GradientStop Color="#2C73924F" Offset="0"/>
										<GradientStop Color="#00FFFFFF" Offset="1"/>
									</LinearGradientBrush>
								</Rectangle.Fill>
							</Rectangle>
							<Rectangle Stroke="{x:Null}" RadiusX="10" RadiusY="10" Margin="0,0,0,0" x:Name="ButtonBase" Opacity="1">
								<Rectangle.Fill>
									<LinearGradientBrush EndPoint="0.843,0.853" StartPoint="0.157,0.147">
										<GradientStop Color="#FF4C913E" Offset="0"/>
										<GradientStop x:Name="NormalButtonBase" Color="#5FB0D341" Offset="1"/>
									</LinearGradientBrush>
								</Rectangle.Fill>
							</Rectangle>
							<Rectangle Stroke="{x:Null}" RadiusX="10" RadiusY="10" Margin="1,1,1,1" x:Name="GlassyTop">
								<Rectangle.Fill>
									<LinearGradientBrush EndPoint="0.507,0.463" StartPoint="0.5,-0.008">
										<GradientStop Color="#7FFFFFFF" Offset="0.311"/>
										<GradientStop Color="#00FFFFFF" Offset="1"/>
									</LinearGradientBrush>
								</Rectangle.Fill>
							</Rectangle>
							<ContentPresenter SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" RecognizesAccessKey="True" Margin="1,1,1,1" TextElement.Foreground="White" />
							<Rectangle Stroke="{x:Null}" RadiusX="10" RadiusY="10" x:Name="BottomGlow" Opacity="0.9">
								<Rectangle.Fill>
									<RadialGradientBrush>
										<RadialGradientBrush.RelativeTransform>
											<TransformGroup>
												<ScaleTransform ScaleX="1" ScaleY="1"/>
												<SkewTransform AngleX="0" AngleY="0"/>
												<RotateTransform Angle="0"/>
												<TranslateTransform X="0" Y="0"/>
											</TransformGroup>
										</RadialGradientBrush.RelativeTransform>
										<GradientStop Color="#00000000" Offset="0"/>
										<GradientStop Color="#00FFFFFF" Offset="1"/>
									</RadialGradientBrush>
								</Rectangle.Fill>
							</Rectangle>
						</Grid>
						<ControlTemplate.Triggers>
							<Trigger Property="IsFocused" Value="True"/>
							<Trigger Property="IsDefaulted" Value="True"/>
							<MultiTrigger>
								<MultiTrigger.EnterActions>
									<BeginStoryboard Storyboard="{StaticResource Timeline1}"/>
								</MultiTrigger.EnterActions>
								<MultiTrigger.ExitActions>
									<BeginStoryboard x:Name="Timeline2_BeginStoryboard" Storyboard="{StaticResource Timeline2}"/>
								</MultiTrigger.ExitActions>
								<MultiTrigger.Conditions>
									<Condition Property="IsMouseOver" Value="True"/>
									<Condition Property="MinWidth" Value="0"/>
								</MultiTrigger.Conditions>
							</MultiTrigger>
							<Trigger Property="IsPressed" Value="True"/>
							<Trigger Property="IsEnabled" Value="False"/>
						</ControlTemplate.Triggers>
					</ControlTemplate>
				</Setter.Value>
			</Setter>
		</Style>
		<!-- Pressed Button Style -->
		<Style x:Key="PressedLinkButtonStyle" BasedOn="{x:Null}" TargetType="{x:Type Button}">
			<Setter Property="Template">
				<Setter.Value>
					<ControlTemplate TargetType="{x:Type Button}">
						<ControlTemplate.Resources>
							<Storyboard x:Key="Timeline1">
								<ColorAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="BottomGlow" Storyboard.TargetProperty="(Shape.Fill).(GradientBrush.GradientStops)[0].(GradientStop.Color)">
									<SplineColorKeyFrame KeyTime="00:00:00" Value="#00000000"/>
									<SplineColorKeyFrame KeyTime="00:00:00.1500000" Value="#FFC2FF00"/>
								</ColorAnimationUsingKeyFrames>
								<ColorAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="BottomGlow" Storyboard.TargetProperty="(Shape.Fill).(GradientBrush.GradientStops)[1].(GradientStop.Color)">
									<SplineColorKeyFrame KeyTime="00:00:00" Value="#00FFFFFF"/>
								</ColorAnimationUsingKeyFrames>
								<DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="BottomGlow" Storyboard.TargetProperty="(Shape.Fill).(Brush.RelativeTransform).(TransformGroup.Children)[3].(TranslateTransform.X)">
									<SplineDoubleKeyFrame KeyTime="00:00:00" Value="-0.019"/>
								</DoubleAnimationUsingKeyFrames>
								<DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="BottomGlow" Storyboard.TargetProperty="(Shape.Fill).(Brush.RelativeTransform).(TransformGroup.Children)[3].(TranslateTransform.Y)">
									<SplineDoubleKeyFrame KeyTime="00:00:00" Value="0.59"/>
									<SplineDoubleKeyFrame KeyTime="00:00:00.1500000" Value="0.535"/>
								</DoubleAnimationUsingKeyFrames>
								<DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetName="BottomGlow" Storyboard.TargetProperty="(Shape.Fill).(Brush.RelativeTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleX)">
									<SplineDoubleKeyFrame KeyTime="00:00:00" Value="1.938"/>
								</DoubleAnimationUsingKeyFrames>
								<DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="BottomGlow" Storyboard.TargetProperty="(Shape.Fill).(Brush.RelativeTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleY)">
									<SplineDoubleKeyFrame KeyTime="00:00:00" Value="0.708"/>
									<SplineDoubleKeyFrame KeyTime="00:00:00.1500000" Value="0.791"/>
								</DoubleAnimationUsingKeyFrames>
								<DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="BottomGlow" Storyboard.TargetProperty="(UIElement.Opacity)">
									<SplineDoubleKeyFrame KeyTime="00:00:00" Value="0.8"/>
									<SplineDoubleKeyFrame KeyTime="00:00:00.1500000" Value="1"/>
								</DoubleAnimationUsingKeyFrames>
							</Storyboard>
							<Storyboard x:Key="Timeline2">
								<ColorAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetProperty="(Shape.Fill).(GradientBrush.GradientStops)[0].(GradientStop.Color)" Storyboard.TargetName="BottomGlow">
									<SplineColorKeyFrame KeyTime="00:00:00" Value="#FFC2FF00"/>
									<SplineColorKeyFrame KeyTime="00:00:00.2600000" Value="#00C2FF00"/>
								</ColorAnimationUsingKeyFrames>
								<ColorAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetProperty="(Shape.Fill).(GradientBrush.GradientStops)[1].(GradientStop.Color)" Storyboard.TargetName="BottomGlow">
									<SplineColorKeyFrame KeyTime="00:00:00" Value="#00FFFFFF"/>
								</ColorAnimationUsingKeyFrames>
								<DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetProperty="(Shape.Fill).(Brush.RelativeTransform).(TransformGroup.Children)[3].(TranslateTransform.X)" Storyboard.TargetName="BottomGlow">
									<SplineDoubleKeyFrame KeyTime="00:00:00" Value="-0.045"/>
								</DoubleAnimationUsingKeyFrames>
								<DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetProperty="(Shape.Fill).(Brush.RelativeTransform).(TransformGroup.Children)[3].(TranslateTransform.Y)" Storyboard.TargetName="BottomGlow">
									<SplineDoubleKeyFrame KeyTime="00:00:00" Value="0.463"/>
								</DoubleAnimationUsingKeyFrames>
								<DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetProperty="(Shape.Fill).(Brush.RelativeTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleX)" Storyboard.TargetName="BottomGlow">
									<SplineDoubleKeyFrame KeyTime="00:00:00" Value="1.933"/>
								</DoubleAnimationUsingKeyFrames>
								<DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Duration="00:00:00.0010000" Storyboard.TargetProperty="(Shape.Fill).(Brush.RelativeTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleY)" Storyboard.TargetName="BottomGlow">
									<SplineDoubleKeyFrame KeyTime="00:00:00" Value="0.919"/>
								</DoubleAnimationUsingKeyFrames>
								<DoubleAnimationUsingKeyFrames BeginTime="00:00:00" Storyboard.TargetName="BottomGlow" Storyboard.TargetProperty="(UIElement.Opacity)">
									<SplineDoubleKeyFrame KeyTime="00:00:00" Value="1"/>
									<SplineDoubleKeyFrame KeyTime="00:00:00.2580000" Value="0.8"/>
									<SplineDoubleKeyFrame KeyTime="00:00:00.2600000" Value="0.9"/>
								</DoubleAnimationUsingKeyFrames>
							</Storyboard>
						</ControlTemplate.Resources>
						<Grid>
							<Rectangle Stroke="{x:Null}" RadiusX="10" RadiusY="10" x:Name="Reflection" Margin="0,0,0,-20.646" VerticalAlignment="Bottom" Height="18">
								<Rectangle.Fill>
									<LinearGradientBrush EndPoint="0.497,0.515" StartPoint="0.499,-0.119">
										<GradientStop Color="#6C73924F" Offset="0"/>
										<GradientStop Color="#00FFFFFF" Offset="1"/>
									</LinearGradientBrush>
								</Rectangle.Fill>
							</Rectangle>
							<Rectangle Stroke="{x:Null}" RadiusX="10" RadiusY="10" Margin="0,0,0,0" x:Name="ButtonBase" Opacity="1">
								<Rectangle.Fill>
									<LinearGradientBrush EndPoint="0.843,0.853" StartPoint="0.157,0.147">
										<GradientStop Color="#FF4C913E" Offset="0"/>
										<GradientStop Color="#FFB0D341" Offset="1"/>
									</LinearGradientBrush>
								</Rectangle.Fill>
							</Rectangle>
							<Rectangle Stroke="{x:Null}" RadiusX="10" RadiusY="10" Margin="1,1,1,1" x:Name="GlassyTop">
								<Rectangle.Fill>
									<LinearGradientBrush EndPoint="0.507,0.463" StartPoint="0.5,-0.008">
										<GradientStop Color="#7FFFFFFF" Offset="0.311"/>
										<GradientStop Color="#00FFFFFF" Offset="1"/>
									</LinearGradientBrush>
								</Rectangle.Fill>
							</Rectangle>
							<ContentPresenter SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" RecognizesAccessKey="True" Margin="1,1,1,1" TextElement.Foreground="White" />
							<Rectangle Stroke="{x:Null}" RadiusX="10" RadiusY="10" x:Name="BottomGlow" Opacity="0.9">
								<Rectangle.Fill>
									<RadialGradientBrush>
										<RadialGradientBrush.RelativeTransform>
											<TransformGroup>
												<ScaleTransform ScaleX="1" ScaleY="1"/>
												<SkewTransform AngleX="0" AngleY="0"/>
												<RotateTransform Angle="0"/>
												<TranslateTransform X="0" Y="0"/>
											</TransformGroup>
										</RadialGradientBrush.RelativeTransform>
										<GradientStop Color="#00000000" Offset="0"/>
										<GradientStop Color="#00FFFFFF" Offset="1"/>
									</RadialGradientBrush>
								</Rectangle.Fill>
							</Rectangle>
						</Grid>
						<ControlTemplate.Triggers>
							<Trigger Property="IsFocused" Value="True"/>
							<Trigger Property="IsDefaulted" Value="True"/>
							<MultiTrigger>
								<MultiTrigger.EnterActions>
									<BeginStoryboard Storyboard="{StaticResource Timeline1}"/>
								</MultiTrigger.EnterActions>
								<MultiTrigger.ExitActions>
									<BeginStoryboard x:Name="Timeline2_BeginStoryboard" Storyboard="{StaticResource Timeline2}"/>
								</MultiTrigger.ExitActions>
								<MultiTrigger.Conditions>
									<Condition Property="IsMouseOver" Value="True"/>
									<Condition Property="MinWidth" Value="0"/>
								</MultiTrigger.Conditions>
							</MultiTrigger>
							<Trigger Property="IsPressed" Value="True"/>
							<Trigger Property="IsEnabled" Value="False"/>
						</ControlTemplate.Triggers>
					</ControlTemplate>
				</Setter.Value>
			</Setter>
		</Style>
	</UserControl.Resources>
	<Canvas Background ="#FF1D0F48">
		<Line Stroke="{DynamicResource BorderBrush}" StrokeThickness="0.5" Canvas.Left="10" X1="60" Y1="0" X2="60" Y2="260" ></Line>
		<StackPanel Name ="panel" Margin="10" HorizontalAlignment="Center">
			<DockPanel Name="SampleDockPanel">
				<Line Stroke="Red" StrokeThickness="2"></Line>
				<Button Style="{DynamicResource NormalLinkButtonStyle}" Name="SampleButton" Width="38" Height="39" Margin="40,30,0,0" DockPanel.Dock="Left" Opacity="0.9">
					<Image Name="SampleButtonIcon" Source="../../Images/Add_Position.png" HorizontalAlignment="Center" VerticalAlignment="Center" Margin="2" Width="25" Height="25"></Image>
				</Button>
				<TextBlock Name="SampleButtonName" Text="" DockPanel.Dock="Left" VerticalAlignment="Bottom" Margin="10,0,10,0" Foreground="White"></TextBlock>
			</DockPanel>
		</StackPanel>
	</Canvas>
</UserControl>

